package com.stone.design.practice.comparable;

import java.util.ArrayList;
import java.util.Collections;
import java.util.List;

/**
 * @author Stone
 * @version V1.0
 * @description:
 * @date 5/8/18 22:51
 * @email redsstone@163.com
 */
public class MainText {

    public static void main(String[] args) {
        Student student = new Student("一一", "女");
        Student student1 = new Student("小石头", "女");
        Student student2 = new Student("王", "女");
        Student student3 = new Student("找", "女");
        Student student4 = new Student("邓平", "女");
        Student student5 = new Student("高老", "女");
        Student student6 = new Student("张三", "女");
        Student student7 = new Student("韩u", "女");

        List<Student> list = new ArrayList<>();
        list.add(student);
        list.add(student1);
        list.add(student2);
        list.add(student3);
        list.add(student4);
        list.add(student5);
        list.add(student6);
        list.add(student7);
        Collections.sort(list);

        for (Student s: list) {
            System.out.println(s.toString());
        }






    }
}
